package com.dycong.common.function;

import java.util.function.Supplier;

/**
 * Created by yu on 16-4-14.
 */
@FunctionalInterface
public interface ThrewSupplier<T> extends Supplier<T> {

    T threwGet() throws Throwable;

    @Override
    default T get() {
        try {
            return threwGet();
        } catch (Throwable throwable) {
            throw new RuntimeException(throwable);
        }
    }
}
